left user from the list of users and informs other users that So-and-so has left. At the same time, the Gone command can set the Boolean variable keepalive to False to end the thread that connects to the client. The ServiceClient () function is as follows:
private void ServiceClient ()
{
Socket client = Clientsocket;
BOOL KeepAlive = true;
while (keepalive)
{
byte[] buffer = new byte[1024];
Client. Receive (buffer);
String clientcommand = System.Text
variable keepalive to false to end the thread connected to the client. The serviceclient () function is as follows:Private void serviceclient (){Socket Client = clientsocket;Bool keepalive = true;While (keepalive){Byte [] buffer = new byte [1024];Client. Receive (buffer );String clientcommand = system. Text. encoding. ASCII. getstring (buffer );String [] tokens = clientcommand. Split (New char [] {'| '});C
processes various client commands. The server receives the string from the client in ASCII code, which contains a separator in the form of "|. The previous part of the string "|" is a specific command, including the CONN, CHAT, PRIV, and GONE types. The CONN command establishes a new client connection, sends the existing user list to the new user, and notifies other users that a new user is added. The CHAT Command sends new information to all users. The PRIV Command sends a private message to a
side receives an ASCII-given string from the client, which contains a "|" The delimiter of the form. "|" in the string The previous sections were specific commands, including Conn, CHAT, PRIV, gone four types. The conn command establishes a new client connection, sends an existing list of users to the new user, and informs the other user that a new user has joined. The chat command sends the new information to all users. The Priv command sends a private whisper to a user. The Gone command remov
added. The CHAT Command sends new information to all users. The PRIV Command sends a private message to a user. The GONE command removes an existing user from the user list and notifies other users that the user has left. At the same time, the GONE command can set the Boolean variable keepalive to false to end the thread connected to the client. The ServiceClient () function is as follows:Private void ServiceClient (){Socket client = clientsocket;Bool keepalive = true;While (keepalive){Byte []
Today I met
XML
Attribute Value reading problem, first fromCodeNo errors are found in the train of thought and syntax query problems,
Then I found the problem from the client and the server's response information.
XML
The property value does not appear in this
XML
String (
XML
The string is determined based on the client commands that contain those attributes, that is, different client action commands will send different
XML
String), so an error occurs.
String
commands:/usr/bin/mysqladmin-u root password ' new-password '/usr/bin/mysqladmin-u root-h localhost.localdomain password ' new-password 'See the Manual for more instructions.Problems with The/usr/bin/mysqlbug script!The latest information about MySQL was available on the Web atHttp://www.mysql.comSupport for MySQL by buying support/licenses at http://shop.mysql.comStarting MySQL. [OK]2. Install the ClientCommand: RPM-IVH mysql-client-5.1.20-0.glibc23
by the window's firewall opening, which can be resolved by shutting down the firewall.Iv. Uninstall and install MySQL under Linux1. Find out if MySQL was previously installedCommand: Rpm-qa|grep-i MySQLYou can see two of the MySQL packages:mysql-4.1.12-3.rhel4.1mysqlclient10-3.23.58-4.rhel4.12. Delete MySQLDelete command: RPM-E--nodeps package Name(Rpm-ev mysql-4.1.12-3.rhel4.1)3, delete the old version of MySQL development header files and librariesCommand: Rm-fr/usr/lib/mysqlRm-fr/usr/include
development package contains the Java package 2.4.0a. Therefore, this version of protobuf is also selected.
2. Deployment
For ease of operation, I put these libraries in a project and run them using BAT. The specific project structure is as follows:
Click Run. BAT to generate a JavaCodeYou only need to introduce this project to the developed project.
After reading this, do you know what I want to do next?
Currently, a problem occurs: protobuf has no inheritance relationship
options = raw
Copy CodeAlso need to add:
[MyShare]
Comment = Share for users
Path =/samba
browseable = yes
writable = yes
public = No
Copy CodeCreate directory: Mkdir/sambaModify Permissions: chmod 777/sambaTo create a system account:Useradd user1Useradd User2Add User1/user2 as a Samba account:Pdbedit-a user1Pdbedit-a User2List all Samba accounts: pdbedit–lRestart Service Services SMB restartTest: Browser Input File://192.168.0.22/myshare6. Linux
a , Task Introduction:Account NumberSyncTask,Syncobject is the database account information and thePublishing Machineof local accounts,itis a background service program that listens on a port, receives requests from clients,processingfour types from the clientCommand:(1 )Scanfull table, Sync account;(2) Add the specified account number;(3) Disables the specified account(4 ) generatesBHOConfigurationfile. where Commands(1)mostComplex,need toconsider bo
It's all right today. Zabbix Action executes the remote command, got a morning, finally good. It is now recorded, for later to appear similar problems can be consulted.First, the service I want to monitor is Nginx/mysqld, which opens the remote execute command on the client to be monitored.Enableremotecommands=1Then add permissions on the clientCommand #visudoAt the end of the add# allows ' Zabbix ' user to run all commands without password.Zabbix All
in path;4) Verify that the installation is successfulIf this is considered a success, check the Configuration environment columnFour. Install Python1: Download Python's latest version from the Python website, typically MSI file2: Installation processRun the downloaded MSI file and tick all the components when you install the component. Special note tick on Pip and add Python.exe to path, then click Next to complete the installation . Install to C drive by default3: Verify that the installation
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.